#include<iostream>
using namespace std;
#include<map>
class comparem {

public:
	bool operator()(int v1,int v2) {
		return v1 > v2;
	}
};
void printmap(map<int, int, comparem >& m) {


}

void test01() {

	map<int, int, comparem>m;
	m.insert(pair<int, int>(1, 10));
	m.insert(pair<int, int>(2, 20));
	m.insert(pair<int, int>(3, 40));
	m.insert(pair<int, int>(5, 60));

	for (map<int, int, comparem >::iterator it = m.begin(); it != m.end(); it++) {

		cout << it->first << "  " << it->second << endl;
	}
	cout << endl;



}
int main() {
	test01();

	system("pause");
	return 0;
}